When failing a migration / save due to the domain owning a PCI device
make sure that we tell the user what went wrong!
Signed-off-by: Mark Williamson <mark.williamson@cl.cam.ac.uk>
except:
log.exception("Failed to reset the migrating domain's name")
+ raise exn
+
def restore(xd, fd, dominfo = None, paused = False):
signature = read_exact(fd, len(SIGNATURE),
try:
XendCheckpoint.save(fd, dominfo, False, False, dst,
checkpoint=checkpoint)
- finally:
+ except Exception, e:
os.close(fd)
+ raise e
+ os.close(fd)
except OSError, ex:
raise XendError("can't write guest state file %s: %s" %
(dst, ex[1]))